import { RouteRecordRaw } from 'vue-router';

const router: RouteRecordRaw[] = [
  {
    path: '/mall',
    name: 'mall',
    redirect: { name: 'mallLayout' },
    component: () => import('@/layouts/LayoutFirst.vue'),
    children: [
      {
        path: '/mall/',
        name: 'mallLayout',
        redirect: { name: 'mallOrder' },
        component: () => import('@/layouts/LayoutSecond.vue'),
        children: [
          { path: '/mall/order', name: 'mallOrder', component: () => import('@/pages/mall/views/order.vue') },
          { path: '/mall/goods', name: 'mallInquiry', component: () => import('@/pages/mall/views/goods.vue') },
          { path: '/mall/classify', name: 'mallClassify', component: () => import('@/pages/mall/views/classify.vue') },
          { path: '/mall/price', name: 'mallPrice', component: () => import('@/pages/mall/views/price.vue') },
          { path: '/mall/activity', name: 'mallActivity', component: () => import('@/pages/mall/views/activity.vue') },
        ],
      },
    ],
  },
];

export default router;
